let { db } = require('../../tools');


module.exports = (req, res) => {
    let { _id } = req.query;
    db.collection('role')
        .deleteOne({_id})
            .then(data => {
                res.json({errno: 0, msg: '删除成功'})
            })
            .catch(err => res.json(err))
}